Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create $ pip3 install blockcypher$ pip3 install blockcypher #170

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Spunky13184
Copy link

import requests
from flask import Flask, request, jsonify

app = Flask(__name__)

# Replace with your actual values
API_TOKEN = 'ca48b6efcdb240d1bfa01e8c7643bc01'  # BlockCypher API token
ADDRESS = 'bc1q4m6yfqwlu6gwq20fuxrx37p7kze9a2fnts5aq0'  # Your cryptocurrency address
WEBHOOK_URL = 'https://abc123.ngrok.io/webhook'  # Replace with your actual Ngrok URL

def create_webhook():
    """Create a webhook with BlockCypher."""
    url = 'https://api.blockcypher.com/v1/btc/main/hooks'
    data = {
        "url": WEBHOOK_URL,
        "event": "tx-confirmation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant